home *** CD-ROM | disk | FTP | other *** search
- /************************************************************************/
- /* */
- /* Source - 4th Debugger.h */
- /* Author - Alexander S. Colwell, Copyright © 1990 */
- /* */
- /* Purpose - This 4th Dimension's external area debugger include file.*/
- /* */
- /************************************************************************/
-
- #ifndef _4thDebugger_ /* Check if has been include yet */
- #define _4thDebugger_ /* Mark it has been included */
-
- #include <Global.h> /* Global variable defs */
- #include <CApplication.h> /* Application object defs */
- #include <Commands.h> /* Command object defs */
- #include <CBartender.h> /* Menu object defs */
- #include <CDecorator.h> /* Window display object defs */
- #include <CDesktop.h> /* Desktop layer object defs */
- #include <CDocument.h> /* Document object defs */
- #include <CEditText.h> /* Text edit object defs */
- #include <CScrollPane.h> /* Scrolling pane object defs */
- #include "4th Class.h" /* 4th Ext Area Class defs */
-
- /* Min/Max defs */
- #define maxDbgChars 8000 /* Maximum # of chars in debug window*/
-
- /* Window/Dialog ID defs */
- #define eaWIND 500 /* "External Area" WIND template */
- #define dbgWIND 501 /* Debugger WIND template */
- #define atDLOG 500 /* "About This..." DLOG */
-
- /* External area commands */
- #define eaOpen 1024 /* Open "External Area" command */
- #define eaClose 1025 /* Close "External Area" command */
- #define ep1 1026 /* Run "External Proc #1" command */
- #define ep2 1027 /* Run "External Proc #2" command */
- #define ep3 1028 /* Run "External Proc #3" command */
- #define ep4 1029 /* Run "External Proc #4" command */
- #define ep5 1030 /* Run "External Proc #5" command */
- #define ep6 1031 /* Run "External Proc #6" command */
- #define ep7 1032 /* Run "External Proc #7" command */
- #define ep8 1033 /* Run "External Proc #8" command */
- #define ep9 1034 /* Run "External Proc #9" command */
- #define eaSelectAll 1035 /* Edit "Select All" command */
- #define eaDebugger 1036 /* Edit "Hide/Show Debugger" command*/
-
- struct CEAPane : CPanorama { /* External area pane object */
-
- /* Variable instances */
- Rect eaRect; /* External rect area */
- Rect eaSRect; /* Scrolled external rect area */
- C4th *eaObject; /* External 4th object handle */
- Point lastWhere; /* Last where event mouse position */
-
- /* Method instances */
- void Dispose(void); /* Dispose ext area method */
- void UpdateMenus(void); /* Update menu items method */
- void AdjustToEnclosure(Rect *);/* Adjust to enclosure area */
- void AdjustCursor(Point, RgnHandle);/* Adjust cursor method */
- void Dawdle(long *); /* Dawdle (Idle) method */
- void Draw(Rect *); /* Draw method */
- void Scroll(short,short,Boolean);/* Scroll method */
- void DoClick(Point,short,long);/* Mouse down method */
- void DoKeyDown(char,Byte,EventRecord *);/* Key-down event method */
- void DoAutoKey(char,Byte,EventRecord *);/* Key-down event method */
- void Activate(void); /* Activate pane method */
- void Deactivate(void); /* Deactivate pane method */
- void DoCommand(long); /* Command method */
- void DoSendEvent(short); /* Send event method */
- void DoExtEvent(EventRecord *);/* Execute ext area procedure */
- void DoExtProc(short); /* Execute ext area procedure */
- short DoGetModifiers(void); /* Get current modifiers */
- };
-
- struct CDbgDoc : CDocument { /* Debugger (bogus) document object */
-
- /* Method instances */
- Boolean Close(Boolean); /* Close */
- };
-
- struct CDbgPane : CEditText { /* Text edit pane object */
-
- /* Variable instances */
- short maxChars; /* Maximum number of characters */
-
- /* Method instances */
- void DoPrint(char *, ...); /* Do print output stream */
- };
-
- /* 4th Debugger classes */
- struct C4thDbgApp : CApplication { /* Application object */
-
- /* Variable instances */
- CDocument *eaDoc; /* External Area window document */
- CDbgDoc *dbgDoc; /* Debugger window document */
- Str255 eaName; /* External area name */
- Rect eaIRect; /* External initial rect area */
- ProcPtr eaProc[10]; /* External procedure table */
-
- /* Methods */
- void IApplication(short,Size,Size);/* Initialization */
- void InitExtArea(void); /* Init external area */
- void InstallExtProc(short,ProcPtr);/* Install external procedure */
- void SetExtArea(short,short,short,short);/* Set ext rect area */
- void SetExtName(char *); /* Set external name */
- void CreateDocument(void); /* Create debugger window */
- void CreateExtArea(void); /* Create external area window */
- void DoCommand(long); /* Command */
- void UpdateMenus(void); /* Update menu items */
- void AboutThis(void); /* About this dialog */
- };
-
- /* Define external references */
- extern C4thDbgApp *gApplication;/* Application object */
- extern CDecorator *gDecorator;/* Window display object */
- extern CDesktop *gDesktop; /* Desktop view layer object */
- extern CBartender *gBartender;/* Menu handler object */
-
- #endif